package cn.topcodes.tcsf.cms.domain.form;

import cn.topcodes.tcsf.admin.commons.domain.Idable;
import lombok.Data;

import java.util.Date;

import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;

import org.springframework.format.annotation.DateTimeFormat;

/**
 * 文章表单
 *
 * @author Unicorn
 * @date 2017-12-25 21:34:53
 */
@Data
public class ArticleForm implements Idable {

    private Long id;

    @NotNull(message = "标题不能为空")
    @Length(min = 0, max = 200, message = "标题长度为0~200个字符")
    private String title;

    @NotNull(message = "摘要不能为空")
    @Length(min = 0, max = 2000, message = "摘要长度为0~2000个字符")
    private String summary;

    private Boolean isTop;

    private Boolean isShow;

    private Boolean isComment;

    @NotNull(message = "内容不能为空")
    private String content;

    @NotNull(message = "关键词不能为空")
    private String keyword;

}